export default {
  app_name: 'IM',
  http_protocol: 'http',
  host: '172.29.100.251',
  http_port: 9200,
  ws_port: 9201,
  init: '/im/user/init',
  his_url: '/im/message/list',
  chat_users_url: '/im/user/groupUsers',
  register_url: '/im/user/register',
  ws_protocol: 'ws',

  getHostUrl: function() {
    return this.http_protocol + '://' + this.host + ':' + this.http_port;
  },

  getChatUsersUrl: function() {
    return this.getHostUrl() + this.chat_users_url;
  },

  getHisUrl: function() {
    return this.getHostUrl() + this.his_url;
  },

  getRegisterUrl: function() {
    return this.getHostUrl() + this.register_url;
  },

  getWsUrl: function() {
    return this.ws_protocol + '://' + this.host + ':' + this.ws_port;
  }
};
